class Moment {
  String id, title, content, created, video, avatar, name, images, createdBy;

  Moment({
    this.id,
    this.title,
    this.content,
    this.created,
    this.video,
    this.avatar,
    this.name,
    this.images,
    this.createdBy,
  });

  factory Moment.fromJson(Map<String, dynamic> data) {
    return Moment(
      id: data['id'],
      title: data['postInfoTitle'],
      content: data['postInfoContent'],
      created: data['createDate'],
      video: data['video'],
      avatar: data['avatar'],
      name: data['fullname'],
      images: data['postImages'],
      createdBy: data['createdBy'],
    );
  }

}
